#!/usr/bin/env python3

a = 3
b = 5

#  3    11
     #  01     1
print(a >> 1)

#  5  101
    #  1010    10
print(b << 1)

#  3 011
#  5 101
  #  001  1
print(a & b)

#  3 011
#  5 101
  #  111  7
print(a | b)

#  3 011
#  5 101
  #  110  6
print(a ^ b)

#  3 11
  #  1111...111100
print(~a)

